Electronic devices, such as smart phones, tablet computers, digital media players, and so forth, increasingly employ optical sensors to control the manipulation of a variety of functions provided by the device. For example, optical sensors are commonly used by electronic devices to detect ambient lighting conditions in order to control the brightness of the device's display screen. Similarly, optical sensors are commonly used in proximity and gesture sensing applications. Proximity and gesture sensing enables the detection of physical movement (e.g., “gestures”) without the user actually touching the device within which the sensing device resides. The detected movements can be subsequently used as input commands for the device.